﻿namespace Mars.Event
{
    /// <summary>
    /// 空事件
    /// </summary>
    public sealed class EmptyEventArgs : BaseEventArgs
    {
        private static string _eventId = typeof(EmptyEventArgs).FullName;

        public override void Clear()
        {
        }

        public override string Id
        {
            get { return _eventId; }
        }

        /// <summary>
        /// 创建空事件
        /// </summary>
        /// <param name="eventId">事件编号</param>
        /// <returns>空事件对象</returns>
        public static EmptyEventArgs Create(string eventId)
        {
            var eventArgs = new EmptyEventArgs();
            eventArgs.SetEventId(eventId);
            return eventArgs;
        }

        /// <summary>
        /// 设置事件编号
        /// </summary>
        /// <param name="eventId"></param>
        private void SetEventId(string eventId)
        {
            _eventId = eventId;
        }
    }
}